<{php}>
	$itemhandler = & xoops_getmodulehandler("item","neoobject");
	$idx_cityH = & xoops_getmodulehandler('idx_city','neogeo');
	$item = & $itemhandler->create();
	if (get_class($item) != 'neoobjectitem') {return false;}
	$item->idx_cities = $idx_cityH->getObjects();  
	$this->assign_by_ref("item", $item);
	$this->assign_by_ref("itemhandler", $itemhandler);
<{/php}>

<form action="submit.php?op=create_ok" method=POST >
<table class="outer" cellspacing="1" width="100%">
<tbody>
<tr><th colspan="2"><{$smarty.const._MA_neoobject_ITEM_ADD}></th></tr>
<tr align="left" valign="top">
<td class="head"><{$smarty.const._MA_neoobject_ITEM_TITLE}></td>
<td class="even"><input name="item_title" id="item_title" size="50" maxlength="255" value="" type="text"></td>
</tr>
<tr align="left" valign="top"><td class="head"><{$smarty.const._MD_GOOOBJECT_ITEM_CITY}></td>
<td class="even"><select size="1" name="item_city_id" id="item_city_id">
<{foreach item=idx_cityO from=$item->idx_cities}>
	<{if $idx_cityO->getVar('city_id')==$smarty.session.neoobject.item.city_id}>
		<option selected value="<{$idx_cityO->getVar("city_id")}>"><{$idx_cityO->getVar("country_title")}>>><{$idx_cityO->getVar("region_title")}>>><{$idx_cityO->getVar("city_title")}></option>	
	<{else}>
		<option value="<{$idx_cityO->getVar("city_id")}>"><{$idx_cityO->getVar("country_title")}>>><{$idx_cityO->getVar("region_title")}>>><{$idx_cityO->getVar("city_title")}></option>	
	<{/if}>
<{/foreach}>
</select></td></tr>
<tr align="left" valign="top"><td class="head"><{$smarty.const._MD_GOOOBJECT_ITEM_TYPE_ID}></td>
<td class="even"><select size="1" name="item_type_id" id="item_type_id">
<{foreach item=type from=$itemhandler->typeH->getObjects()}>
	<{if $type->getVar('id')==$smarty.session.neoobject.item.type_id}>
		<option selected value="<{$type->getVar("id")}>"><{$type->getVar("title")}></option>	
	<{else}>
	<option  value="<{$type->getVar("id")}>"><{$type->getVar("title")}></option>	
	<{/if}>
<{/foreach}>
</select></td></tr>
<tr align="left" valign="top"><td class="head"><{$smarty.const._MD_GOOOBJECT_ITEM_STARSNUM}></td>
<td class="even"><select size="1" name="item_stars" id="item_stars">

<{foreach item=star from=$itemhandler->stars}>
	<{if $star==$smarty.session.neoobject.item.star}>
		<option selected value="<{$star}>"><{$star}></option>	
	<{else}>
	<option  value="<{$star}>"><{$star}></option>	
	<{/if}>
<{/foreach}>
</select></td></tr>
<tr align="left" valign="top">
<td class="head"><{$smarty.const._MA_neoobject_ITEM_ADDRESS}></td>
<td class="even"><input name="item_address" id="item_address" size="50" maxlength="255" value="" type="text"></td>
</tr>
<tr align="left" valign="top"><td class="head"><{$smarty.const._MA_neoobject_ITEM_PHONE}></td>
<td class="even"><input name="item_phone" id="item_phone" size="50" maxlength="255" value="" type="text"></td>
</tr>
<tr align="left" valign="top"><td class="head"><{$smarty.const._MA_neoobject_ITEM_URL}></td>
<td class="even">
<input name="item_url" id="item_url" size="50" maxlength="255" value="" type="text"></td>
</tr>
<tr align="left" valign="top"><td class="head"><{$smarty.const._MA_neoobject_ITEM_EMAIL}></td>
<td class="even"><input name="item_email" id="item_email" size="50" maxlength="255" value="" type="text"></td>
</tr>
<tr align="left" valign="top"><td class="head"><{$smarty.const._MA_neoobject_ITEM_DESCRIPTION}></td>
<td class="even">
<!--<textarea name="item_description" id="item_description" rows="5" cols="50"></textarea></td>-->
<{gocodetarea name="item_description" value=''}>

</tr></tbody></table>



<input type=submit>


</form>
